import {
	MyRequest
} from '@/util/api.js'

//拿到所有评论
export const getAllCommentary = (articleId, current, size) => MyRequest({
	url: '/comment/wx/listAllComments',
	method: 'get',
	data: {
		articleId,
		current,
		size
	}
})

//根据一级评论拿到二级评论
export const getTwoCommentary = (rootId) => MyRequest({
	url: '/comment/wx/listCommentsByRoot',
	method: 'get',
	params: {
		rootId
	}
})
//发布评论
export const putCommentary = (data) => MyRequest({
	url: '/comment/wx/sava',
	method: 'post',
	data
})
